Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Rotations #114

Merged
merged 41 commits into from Dec 18, 2019
Merged

Add Rotations #114

merged 41 commits into from Dec 18, 2019

Conversation

BGMP
Copy link
Contributor

@BGMP BGMP commented Dec 13, 2019

Did my best to implement them correctly.

@BGMP BGMP requested a review from Electroid as a code owner December 13, 2019 08:17
Copy link
Contributor

@TheMolkaPL TheMolkaPL left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The rest looks good to me.

src/main/java/tc/oc/pgm/rotation/Rotation.java Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/rotation/Rotation.java Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/rotation/RotationManager.java Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/rotation/RotationManager.java Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/rotation/RotationManager.java Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/rotation/RotationManager.java Outdated Show resolved Hide resolved
src/main/resources/rotations.yml Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/commands/RotationCommands.java Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/commands/RotationCommands.java Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/commands/RotationCommands.java Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/commands/RotationCommands.java Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/rotation/PGMMapOrderProvider.java Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/rotation/Rotation.java Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/rotation/RotationManager.java Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/rotation/RotationManager.java Outdated Show resolved Hide resolved
src/main/java/tc/oc/pgm/rotation/RotationManager.java Outdated Show resolved Hide resolved
src/main/resources/rotations.yml Outdated Show resolved Hide resolved
@Pablete1234
Copy link
Member

I had already told him this, but basically PGMMapOrderProvider is the only interface that the general code should be using. methods like "getRotationManager" assume there's a rotation, when there may not be one (eg: random map ordering, or voting based next map).

The rotation commands should be testing if matchManager.getMapOrder() is instance of a RotationManager, and if it isn't, just inform the user a rotation isn't in use.

Then commands like /setnext or /next can use directly the PGMMapOrderProvider interface as that's all they need to interact with

@BGMP
Copy link
Contributor Author

BGMP commented Dec 17, 2019

I had already told him this, but basically PGMMapOrderProvider is the only interface that the general code should be using. methods like "getRotationManager" assume there's a rotation, when there may not be one (eg: random map ordering, or voting based next map).

The rotation commands should be testing if matchManager.getMapOrder() is instance of a RotationManager, and if it isn't, just inform the user a rotation isn't in use.

Then commands like /setnext or /next can use directly the PGMMapOrderProvider interface as that's all they need to interact with

Oke, I have implemented them the way you have requested me to: fe83e3a

@BGMP BGMP requested a review from Electroid December 17, 2019 09:34
Copy link
Member

@Electroid Electroid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So close @BGMP. Can you remove the System.out.println and change next_map to nextMap and I'll merge it up 🎉

@Electroid
Copy link
Member

@BGMP Go ahead and look at @Pablete1234's suggestions first

@BGMP
Copy link
Contributor Author

BGMP commented Dec 18, 2019

@Electroid I am. Almost done

Pugzy and others added 16 commits December 18, 2019 02:28
Signed-off-by: Pugzy <pugzy@mail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: ThatOneTqnk <nodeadbatteries@gmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: botinator <53882853+botinator@users.noreply.github.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: Pablete1234 <pabloherrerapalacio@gmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: botinator <53882853+botinator@users.noreply.github.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
…operly

Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: Pugzy <pugzy@mail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: Ashcon Partovi <ashcon@partovi.net>
Signed-off-by: BGM <bgmp00@protonmail.com>
Electroid and others added 24 commits December 18, 2019 02:29
Signed-off-by: Ashcon Partovi <ashcon@partovi.net>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: Ashcon Partovi <ashcon@partovi.net>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: Brottweiler <brottsie@gmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
…LOBAL

Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: Meeples10 <8867705+Meeples10@users.noreply.github.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
…ions.yml

Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: botinator <53882853+botinator@users.noreply.github.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Co-Authored-By: Pablo Herrera <pabloherrerapalacio@gmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Co-Authored-By: Pablo Herrera <pabloherrerapalacio@gmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: Pugzy <pugzy@mail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
Signed-off-by: BGM <bgmp00@protonmail.com>
@BGMP
Copy link
Contributor Author

BGMP commented Dec 18, 2019

Blame DCO for the mess

Signed-off-by: BGM <bgmp00@protonmail.com>
@Electroid Electroid merged commit 2c12aa3 into PGMDev:master Dec 18, 2019
Copy link
Member

@Pablete1234 Pablete1234 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The PR was merged already, but still those 2 minor changes should be made. Good job for getting this feature finished tho

@Pablete1234 Pablete1234 mentioned this pull request Dec 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

8 participants